﻿<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ include file="../common/taglibs.jsp" %>
<c:if test="${fn:length(triggers)>0}">
		<table id="scheduler">
			<tr>
				<th>Submitter</th>
				<th>Type</th>
				<th>Definition</th>
				<th>Description</th>
				<th>Parameters</th>
				<th>Start<br>Time</th>
				<th>End<br>Time</th>
				<th>Next<br>Fire Time</th>
				<th>Previous<br>Fire Time</th>
				<th>Final<br>Fire Time</th>
				<th>Misfire<br>Instruction</th>
				<th>Action</th>
			</tr>
<c:forEach var="trigger" items="${triggers}">
			<tr valign="top">
				<td>${trigger.jobDataMap["job.submitter"]} </td>
				<td><c:choose>
					<c:when test='${trigger["class"].simpleName=="CronTriggerImpl"}'>Cron</c:when>
					<c:when test='${trigger["class"].simpleName=="SimpleTriggerImpl"}'>Simple</c:when>
				</c:choose></td>
				<td><c:choose>
					<c:when test='${trigger["class"].simpleName=="CronTriggerImpl"}'>${trigger.cronExpression}</c:when>
					<c:when test='${trigger["class"].simpleName=="SimpleTriggerImpl"}'>${trigger.repeatCount}/${trigger.repeatInterval/1000}</c:when>
				</c:choose></td>
				<td>${trigger.description}</td>
				<td><c:forEach var="key" items='${trigger.jobDataMap["job.parameters"]}' varStatus="vsk"><c:if test="${vsk.index>0}"><BR></c:if>${key}</c:forEach></td>
				<td>${ss:dateFormat(trigger.startTime.time)}</td>
				<td>${ss:dateFormat(trigger.endTime.time)}</td>
				<td>${ss:dateFormat(trigger.nextFireTime.time)}</td>
				<td>${ss:dateFormat(trigger.previousFireTime.time)}</td>
				<td>${ss:dateFormat(trigger.finalFireTime.time)}</td>
				<td>${trigger.misfireInstruction}</td>
				<td>
					<a href="run-job-conf.action?action=createTrigger&identifier=${conf.identifier.stringIdentifier}&triggerIdentifier=${trigger.key.name}"><img alt="以此为模板创建" src="images/icons/add.png" title="以此为模板创建"></a>
					<a href="run-job-conf.action?action=removeTrigger&identifier=${conf.identifier.stringIdentifier}&triggerIdentifier=${trigger.key.name}"><img alt="删除调度" src="images/icons/remove.jpg" title="删除调度"></a>
				</td>
			</tr>
</c:forEach>
		</table>
</c:if>